// 查询列表接口
const getCategoryPage = (params) => {
  return $axios({
    url: '/posts/page',
    method: 'get',
    params
  })
}

// 获取部门列表
const getdeptList = () => {
  return $axios({
    url: '/dept/findByDept',
    method: 'get',
  })
}

// 修改接口
const editPosts = (params) => {
  return $axios({
    url: '/posts',
    method: 'put',
    data: { ...params }
  })
}

// 新增接口
const addPosts = (params) => {
  return $axios({
    url: '/posts',
    method: 'post',
    data: { ...params }
  })
}

// 查询详情
const findById = (id) => {
  return $axios({
    url: `/posts/findById/${id}`,
    method: 'get'
  })
}

// 删除当前列的接口
const deletePosts = (ids) => {
  return $axios({
    url: '/posts',
    method: 'delete',
    params: { ids }
  })
}



